import request from '@/utils/request'

// 查询押金结算列表
export function listSettlement(query) {
  return request({
    url: '/order/settlement/list',
    method: 'get',
    params: query
  })
}

// 查询押金结算详细
export function getSettlement(id) {
  return request({
    url: '/order/settlement/' + id,
    method: 'get'
  })
}

// 新增押金结算
export function addSettlement(data) {
  return request({
    url: '/order/settlement',
    method: 'post',
    data: data
  })
}

// 修改押金结算
export function updateSettlement(data) {
  return request({
    url: '/order/settlement',
    method: 'put',
    data: data
  })
}

// 删除押金结算
export function delSettlement(id) {
  return request({
    url: '/order/settlement/' + id,
    method: 'delete'
  })
}

// 导出押金结算
export function exportSettlement(query) {
  return request({
    url: '/order/settlement/export',
    method: 'get',
    params: query
  })
}


// 确认押金结算退款
export function depositRefund(orderNo) {
  return request({
    url: 'order/orderBasic/depositRefund/' + orderNo,
    method: 'post',
  })
}
// 确认违章押金结算退款
export function IllegalRefund(orderNo) {
  return request({
    url: 'order/orderBasic/IllegalRefund/' + orderNo,
    method: 'post',
  })
}
